package drds.global_transaction.global_transaction_manager.api;

import drds.global_transaction.api.api.GlobalTransactionStatus;
import drds.global_transaction.api.exception.GlobalTransactionException;

public interface GlobalTransaction
{

	void begin() throws GlobalTransactionException;

	void begin(int timeout) throws GlobalTransactionException;

	void begin(int timeout, String name) throws GlobalTransactionException;

	//
	String getGlobalTransactionIdWithAddressAndPort();

	//
	void commit() throws GlobalTransactionException;

	void rollback() throws GlobalTransactionException;

	//
	GlobalTransactionStatus getGlobalTransactionStatus() throws GlobalTransactionException;

}
